/*
 * Copyright 2020-2021 redragon-erp/赤龙ERP
 * Author redragon/dongbin
 * This file is part of redragon-erp/赤龙ERP.

 * 赤龙ERP官方声明：
 * (1)赤龙ERP的知识产权归软件著作权人所有
 * (2)未经著作权人授权，不得将赤龙ERP用于任何形式的商业用途
 * (3)对侵权的组织或个人，著作权人将保留诉诸法律的权利

 * 赤龙ERP官网详见 <https://www.redragon-erp.com>
 * 赤龙ERP仓库详见 <https://gitee.com/redragon/redragon-erp> 
 * 如遇任何问题，请与著作权人联系
 */
package com.erp.oa.notice.service.spring;

import java.util.List;
import java.util.Map;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import org.redragon.framework.annotation.Cache;
import org.redragon.framework.annotation.Cache.CacheType;
import org.redragon.framework.annotation.Log;
import org.redragon.framework.hibernate.model.Pages;
import com.erp.oa.notice.dao.SysNoticeDao;
import com.erp.oa.notice.dao.model.SysNotice;
import com.erp.oa.notice.dao.model.SysNoticeCO;
import com.erp.oa.notice.service.SysNoticeService;

@Service
@Transactional(rollbackFor=Exception.class)
public class SysNoticeServiceImpl implements SysNoticeService {

    //注入Dao
    @Autowired
    private SysNoticeDao sysNoticeDao;
    
    @Override
    public void insertDataObject(SysNotice obj) {
        this.sysNoticeDao.insertDataObject(obj);
    }

    @Override
    public void updateDataObject(SysNotice obj) {
        this.sysNoticeDao.updateDataObject(obj);
    }
    
    @Override
    public void insertOrUpdateDataObject(SysNotice obj) {
        this.sysNoticeDao.insertOrUpdateDataObject(obj);
    }

    @Override
    public void deleteDataObject(SysNotice obj) {
        this.sysNoticeDao.deleteDataObject(obj);
    }

    @Override
    public List<SysNotice> getDataObjects() {
        return this.sysNoticeDao.getDataObjects();
    }

    @Override
    public SysNotice getDataObject(int id) {
        return this.sysNoticeDao.getDataObject(id);
    }

    @Override
    public SysNotice getDataObject(String code) {
        return this.sysNoticeDao.getDataObject(code);
    }

    @Override
    public List<SysNotice> getDataObjects(SysNoticeCO paramObj) {
        return this.sysNoticeDao.getDataObjects(paramObj);
    }

    @Override
    public List<SysNotice> getDataObjects(Pages pages) {
        return this.sysNoticeDao.getDataObjects(pages);
    }
    
    @Override
    public List<SysNotice> getDataObjects(Pages pages, SysNoticeCO paramObj) {
        return this.sysNoticeDao.getDataObjects(pages, paramObj);
    }
    
    @Override
    public List<Map<String, Object>> getDataObjectsArray(Pages pages, SysNoticeCO paramObj) {
        return this.sysNoticeDao.getDataObjectsArray(pages, paramObj);
    }
    
    @Override
    public List<SysNotice> getDataObjectsForDataAuth(String dataAuthSQL, Pages pages, SysNoticeCO paramObj) {
        return this.sysNoticeDao.getDataObjectsForDataAuth(dataAuthSQL, pages, paramObj);
    }
    
    @Override
    public void updateApproveStatus(int id, String approveStatus) {
        this.sysNoticeDao.updateApproveStatus(id, approveStatus);
    }
    
}